<template>
	<view id="app">
		<view class="container bgw">
			<uv-parse :content="content" :tagStyle="style"></uv-parse>
		</view>
	</view>
</template>

<script>
	let that;
	export default {
		data() {
			return {
				style:{
					p:"font-size:26rpx;",
					image:'with:100%;height:auto;'
				},
				content:"",
				title:""
			}
		},
		onLoad(e){
			that = this;
			this.getlist(e);
		},
		onShow(){
			console.log(that.title);
			setTimeout(function(e){
				console.log(that.title);
				uni.setNavigationBarTitle({
					title:that.title
				})
			},500)
		},
		onReady(){
			console.log('ready');
			console.log(that.title);
			
		},
		methods: {
			getlist:function(e){
				this.request({
					url:"/api/index/content",
					data:e,
					success:function(res){
						if(res.code ='200'){
							that.title = res.data.title;
							that.content = res.data.content;
							console.log(that.title);
						}
					}
				})
			}
		}
	}
</script>

<style>

</style>
